<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script type="text/javascript">
			var arr=[1,2,3,11,22,30];
			 var result1=arr.slice(1,2);    //2
			 var result2=arr.slice(0,-2);  //1,2,3,11
			 console.log("result1="+result1);
			  console.log("result2="+result2);
			  //console.log(arr);        //并不会删除原数组的东西
			 var result3=arr.splice(0,3,"林润钿");//  1,2,3  数组为"林润钿",11,22,30
			  console.log("result3="+result3);
			  console.log(arr);
			
		</script>
	</head>
	<body>
	</body>
</html>